<?php
use yii\web\View;
use yii\widgets\ActiveForm;
/* @var $this yii\web\View */
/* @var $model common\models\User */
$this->registerJsFile('/js/jquery.SuperSlide.2.1.1.js');
$this->registerJsFile('/js/common_js.js', [
    'position' => View::POS_BEGIN
]);
$this->registerCssFile('/css/common.css');
$this->registerCssFile('/fonts/iconfont.css');
$this->registerJsFile('/js/public.js');
$this->registerCssFile('/css/myorder.css');
$this->registerJsFile('/layer/layer.js');
$this->title = '订单详情-锐锋堂刀剑网';
?>
<div class="title_style">
	<em></em>订单详情
</div>
<div class="Order_form_style">
	<div class="Order_form_list">
	<table class='otable'>
		<tr>
			<td style='text-align:left;width:60px'>发货方式:</td>
			<td style='text-align:left;'>快递</td>
		</tr>
		<tr>
			<td style='text-align:left'>快递公司:</td>
			<td style='text-align:left;'><?=$order['bom']['flag']?></td>
		</tr>
		<tr>
			<td style='text-align:left'>快递单号:</td>
			<td style='text-align:left;'><?=$order['waybill']?></td>
		</tr>
		<tr>
			<td style='    vertical-align: top;'>物流跟踪:</td>
			<td style='text-align:left'><ul>
			<?php if(!empty($kd['Traces'])):?>
			<?php foreach($kd['Traces'] as $val):?>
			<li><?=$val['AcceptTime'].$val['AcceptStation']?></li>
			<?php endforeach;?>
			<?php else:?>
			<li>暂无物流信息</li>
			<?php endif;?>
			</ul></td>
		</tr>
	</table>
		<table>
			<thead>
				<tr>
					<td class="list_name_title0">商品</td>
					<td class="list_name_title1">单价(元)</td>
					<td class="list_name_title2">数量</td>
					<td class="list_name_title4">实付款(元)</td>
					<td class="list_name_title5">订单状态</td>
				</tr>
			</thead>
			<?php if(!empty($order)):?>
			<tbody>
				<tr class="Order_info">
					<td colspan="6" class="Order_form_time">
						订单号：<?=$order['omun']?> | 下单时间：<?=date('Y-m-d H:i:s',$val['create_at'])?><em></em></td>
				</tr>
				<tr class="Order_Details">
					<td colspan="3">
						<table class="Order_product_style">
							<tbody>
							<?php if(!empty($order['oinfo'])):?>
							<?php foreach($order['oinfo'] as $v):?>
								<tr>
									<td>
										<div class="product_name clearfix">
											<a href="#" class="product_img"><img src="<?=$v['logo']?>"
												width="80px" height="80px"></a> <a href="3" class="p_name"><?=$v['name']?></a>
											<p class="specification"><?=$v['num']?>/把</p>
										</div>
									</td>
									<td><?=$v['price']?></td>
									<td><?=$v['num']?></td>
								</tr>
							<?php endforeach;?>
							<?php endif;?>
							</tbody>
						</table>
					</td>
					<td class="split_line"><?=$order['price']?></td>
					<?php switch ($order['status']){
                        case 0:echo '<td class="split_line">等待买家付款</td>';break;
                        case 1:echo '<td class="split_line"><p style="color: #F33">买家已付款</p></td>';break;
                        case 2:echo '<td class="split_line"><p style="color: #F30">已发货，待收货</p></td>';break;
                        case 3:echo '<td class="split_line"><p style="color:#F30">交易已成功</p><p style="color:#CCC">未评价</p></td>';break;
                        case 4:echo '<td class="split_line"><p style="color:#F30">交易已成功</p><p style="color:#999">已评论</p></td>';break;
					}
                        ?>
				</tr>
			</tbody>
			<?php endif;?>
		</table>
	</div>
</div>